﻿using System;
using System.Collections.Generic;
using System.Text;

namespace WHO_Auth_TNG_Win {
    public class Base64 {

        public static string Encode(string str) {
            byte[] encbuff = System.Text.Encoding.UTF8.GetBytes(str);
            return Convert.ToBase64String(encbuff);
        }
        public static string Decode(string str) {
            byte[] decbuff = Convert.FromBase64String(str);
            return System.Text.Encoding.UTF8.GetString(decbuff);
        }

    }
}
